package cn.fsd.controller;

import cn.fsd.domain.Station;
import cn.fsd.domain.Suppliers;
import cn.fsd.mapper.SuppliersMapper;
import cn.fsd.service.SupplierService;
import cn.fsd.vo.ResultBean;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@RequestMapping(value = "/bill",produces = "application/json;charset=utf-8")
@Api(value = "财务管理中有关供应商的API",description = "结算信息可以根据供应商查询")
public class SupplierController {

    @Autowired
    SupplierService supplierService;

    @GetMapping //get + /bill
    @ApiOperation(value = "供应商查询框中可以输入部分信息，然后利用搜索功能快速查找选项")
    public ResultBean findAll(){
        List<Suppliers> supplierList = supplierService.findAll();
        return ResultBean.success(supplierList);
    }
}
